package com.itnoob.service.impl;

import com.itnoob.service.Pay;
import org.springframework.context.annotation.Primary;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

import java.math.BigDecimal;

/**
 * @author zhoujun
 * @date 2025/3/18 22:48
 */
@Primary
@Component(value = "WECHAT")
@Scope(value = "prototype")
public class WeChatPay implements Pay {
    @Override
    public void pay(BigDecimal amount) {
        System.out.println("使用微信支付"+ amount + "元");
    }
}
